package com.ruitu.mall_98_2.mvp.model;

import com.ruitu.mall_98_2.dao.APIRetrofit;
import com.ruitu.mall_98_2.mvp.contract.RelevanceTelContract;
import com.ruitu.router_module.bean.User;
import com.ruitu.router_module.bean.api.BaseResult;

import rx.Observable;
import rx.android.schedulers.AndroidSchedulers;
import rx.schedulers.Schedulers;

public class RelevanceTelModel implements RelevanceTelContract.Model {
    @Override
    public Observable<BaseResult<User>> registerForQqOrWx(String openId, String type, String phone, String pwd, String code,String otherName) {
        return APIRetrofit.getDefault().registerForQqOrWx(openId, type, phone, pwd, code,otherName)
                .observeOn(AndroidSchedulers.mainThread())
                .subscribeOn(Schedulers.io());
    }
}
